package com.iot.web;



import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.ApplicationContext;

/**   
 * 说明：EVI 应用启动主入口
 * @Title: EVIApplication.java 
 * @Package com.witsight.hibernate 
 * @See: {@link EVIApplication}<br/>
 * Copyright: Copyright (c) 2017<br/>
 * Company:sany huax witsight team by product
 * @author: penght  
 * @date: 2017年10月16日 上午9:42:46 
 * @version: V1.0
 */
@SpringBootApplication(scanBasePackages = {
		"com.witsight.cassandra",
		"com.iot.core",
		"com.iot.web",
		})
public class EVIApplication {
	// 日志对象
	protected static final Logger LOGGER = LoggerFactory.getLogger(EVIApplication.class);
	/**
	 * 
	 * 说明：EVI 应用启动主入口 main
	 * @Title: main
	 * @See: {@link ApplicationContext}
	 * @author penght
	 * @param args 
	 * @date: 2017年10月16日 上午9:45:58
	 */
	public static void main(String[] args) {
//		TimeZone.setDefault(TimeZone.getTimeZone("UTC"));
//		System.setProperty("user.timezone","GMT+08");
		ApplicationContext ctx = SpringApplication.run(EVIApplication.class, args);
		String[] activeProfiles = ctx.getEnvironment().getActiveProfiles();
		if (activeProfiles == null || activeProfiles.length < 1) {
			return;
		}
		for (String activeProfile : activeProfiles) {
			LOGGER.info("evi using profile is {}",activeProfile);
		}
	}
}
